<template>
  <div class="block" v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.8)">

    <el-carousel class="lunbo" direction="vertical" height="2.8rem" interval="2000" indicator-position="none" style="border-radius: 0.
    
    2rem;">
      <el-carousel-item v-for="(item) in bannerList " :key="item" ref="pic">
        <!-- <h3 class="small">{{ index }}</h3> -->
        <img :src="item.pic" />
      </el-carousel-item>
    </el-carousel>
  </div>

</template>

<script setup>
import { computed, onMounted, ref, nextTick, watch } from 'vue';
import { storeToRefs } from 'pinia'
import { homeStore, } from '@/store/home.js'
const store = homeStore()
let { bannerList } = storeToRefs(store)
let loading = ref(true)
onMounted(() => {
  loading.value = false
})
</script>

<style scoped>
.block {}

img {
  width: 100%;
}

.block {
  width: 7.5rem;
  height: 10%;
  padding: 0 0.1rem;
}

.el-carousel__item h3 {
  color: #475669;
  font-size: 14px;
  opacity: 0.75;
  line-height: 150px;
  margin: 0;
  text-align: center;
}

.el-carousel__item:nth-child(2n) {
  background-color: #99a9bf;
}

.el-carousel__item:nth-child(2n + 1) {
  background-color: #d3dce6;
}
</style>
 